<?php /* УТФ-8:fix */

class SPIview__front extends SPIview__dummy
{
    public function render( $content, $verbose_tpl_filename = null )
    {
        $tpl = SPItpl::I('front');

        $tpl->assign_by_ref('SPIcfg', SPIcfg::as_array() );
        $tpl->assign_by_ref('content', $content);
		$tpl->assign_by_ref('lang', SPI::I('lang'));

        switch( $content[':RENDER_MODE:'] )
        {
            case 'adv_forum':
            {
                return $tpl->compile( $content[':RENDER_TEMPLATE:'] );
            }

            default:
            {
                $tpl->echo_compile( $verbose_tpl_filename ? $verbose_tpl_filename : 'main.tpl' );
                break;
            }
        }

        return true;
    }
}
